package com.changgou.goods.dao;

import com.changgou.goods.pojo.Category;
import org.apache.ibatis.annotations.Select;
import org.springframework.data.repository.query.Param;
import tk.mybatis.mapper.common.Mapper;

import java.util.List;

public interface CategoryMapper extends Mapper<Category> {

    @Select("select name from tb_category where parent_id=#{id}")
    public List<Category> findByParentId(@Param("id") Integer parentId);

}
